<?php


namespace app\api\controller;

use app\BaseController;
use app\common\facade\auth\Auth;
use app\model\AgentChannel;

class Channel extends BaseController
{
    protected $middleware = [
        \app\middleware\ApiChannel::class,
        \app\middleware\ApiUserAuthV2::class => ['except' => ['phoneInfo']],
    ];

    protected function initialize()
    {
        parent::initialize();
    }

    /**
     * 查询具体代理某个渠道是否开启了订单显示入口
     */
    public function getOrderDisStatus()
    {
        $channel_id = Auth::channelId();
        $order_display_status = AgentChannel::query()->where('id', $channel_id)->value('order_display_status');
        return success('请求成功', ['order_display_status' => $order_display_status]);
    }




}